import 'package:flutter/cupertino.dart';
import 'package:flutter/material.dart';
import 'package:fluttermodule/page/OrderMeal/view/MealWidget.dart';
import 'package:fluttermodule/utils/screen.dart';

class OrderMealRecordPage extends StatefulWidget {
  @override
  State<StatefulWidget> createState() {
    return _OrderMealRecordState();
  }
}

class _OrderMealRecordState extends State<OrderMealRecordPage> {
  @override
  Widget build(BuildContext context) {
    setScreenSize(context);
    return Scaffold(
        appBar: AppBar(
          leading: IconButton(
              icon: Image.asset(
                'assets/meal/images/ic_btn_back_white.png',
                width: 32,
                height: 32,
              ),
              iconSize: dpWidth(48),
              onPressed: () {
                Navigator.pop(context);
              }),
          centerTitle: true,
          title: Text(
            "订餐",
            style: TextStyle(color: Colors.white, fontSize: spFont(36)),
          ),
        ),
        body: ListView.separated(
            itemCount: 10,
            itemBuilder: (BuildContext context, int index) {
              return MealRecordItemWidget();
            },
            separatorBuilder: (BuildContext context, int position) {
              return Divider(
                  height: dpHeight(20),
                  color: Color.fromARGB(255, 245, 245, 245));
            }));
  }
}
